package br.com.checkandgo.model;

import java.util.ArrayList;
import java.util.List;

import android.os.Parcel;
import android.os.Parcelable;

import com.google.android.gms.maps.model.LatLng;

public class Route implements Parcelable {
	private String polyline;
	private String nome;
	private String tipo;
	private ArrayList<String> dia;
	
	public Route() {
		super();
	}
	
	public Route(String nomeRota, ArrayList dia,
			Boolean programacao, String googleId) {
		super();
		this.nome = nome;
		this.tipo = tipo;
		this.dia = dia;

	}
	
	public Route(Parcel in){
		nome = in.readString();
		tipo = in.readString();
		dia = in.readArrayList( String.class.getClassLoader());
		polyline = in.readString();
	}
	
	public String getNome() {
		return nome;
	}

	public void setNome(String nome) {
		this.nome = nome;
	}

	public String getTipo() {
		return tipo;
	}

	public void setTipo(String tipo) {
		this.tipo = tipo;
	}

	public ArrayList<String> getDia() {
		return dia;
	}

	public void setDia(ArrayList<String> dia) {
		this.dia = dia;
	}

	public void setPolyline(String polyline) {
		this.polyline = polyline;
	}

	public String getPolyline() {
		return polyline;
	}
	
	@Override
	public int describeContents() {
		return 0;
	}

	@Override
	public void writeToParcel(Parcel dest, int flags) {
		dest.writeString(this.nome);
		dest.writeString(this.tipo);
		dest.writeList(this.dia);
		dest.writeString(this.polyline);
	}
	
	public static final Parcelable.Creator<Route> CREATOR = new Creator<Route>() {

        public Route createFromParcel(Parcel source) {

            return new Route(source);
        }

        public Route[] newArray(int size) {

            return new Route[size];
        }

    };
}
